package com.zofer.study.stream;

import java.util.Arrays;
import java.util.List;
import java.util.stream.Collectors;

/**
 * 值列表
 */
public class StreamTest01 {

    static List<String> list = Arrays.asList("1","2","3","4","5","5");

    public static void main(String[] args) {
        test1();
    }


    public static void test1() {
        // 值列表操作
        List<String> list1 = list.stream()
                .filter(s -> Integer.valueOf(s) > 3)
                .distinct()
                .sorted()
                .collect(Collectors.toList());
        list1.add("12");
        System.out.println("====test1======");
    }

}
